<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags" %>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>My JSP 'messageleave.jsp' starting page</title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
	<link rel="stylesheet" type="text/css" href="css/common.css">

  </head>
  
  <body>
  	<div class="centerdiv">
  	<s:if test="#session.currentUser==null">
  		<jsp:forward page="../login.jsp"></jsp:forward>
  	</s:if>
    <s:form action="jsp_admin_announceadd.action" method="post" theme="simple">
    	<table class="bookadd">
    		<tr class="bookadd_title">
    			<td colspan="2" >新增公告</td>
    		</tr>
    		<tr>
    			<td align="center">
		    		<table>
		    		<tr>
		    			<td>用户名</td>
		    			<td><s:property value="#session.currentUser.username"/></td>
		    		</tr>
		    		<tr>
		    			<td>标题</td>
		    			<td><s:textfield name="title"></s:textfield></td>
		    		</tr>
		    		<tr>
		    			<td>内容</td>
		    			<td><s:textarea name="content" style="height:100px;"></s:textarea></td>
		    		</tr>
		    		<tr>
		    			<td colspan="2" align="right">
		    				<s:submit value="提交"></s:submit>
		    				<s:reset value="重置"></s:reset>
		    				<a href="jsp_admin_announceselect.action">返回</a>
		    			</td>
		    		</tr>
    				</table>
    			</td>
    		</tr>
    		
    	</table>
    </s:form>  	
  	</div>
  </body>
</html>
